import axios from '@/router/axios'

export function getintake (query = {}) {
  return axios.get('/api/root/config/intake/list', {
    params: query
  })
}

export function delintake (id) {
  return axios.post('/api/root/config/intake/del', id)
}

export function addintake (formData) {
  return axios.post('/api/root/config/intake/add', formData)
}

export function updintake (formData) {
  return axios.post('/api/root/config/intake/upd', formData)
}

export function getcollege (query = {}) {
  return axios.get('/api/root/config/college/list', {
    params: query
  })
}

export function delcollege (id) {
  return axios.post('/api/root/config/college/del', id)
}

export function addcollege (formData) {
  return axios.post('/api/root/config/college/add', formData)
}

export function updcollege (formData) {
  return axios.post('/api/root/config/college/upd', formData)
}

export function getallcollege (formData) {
  return axios.get('/api/root/config/college/allList', formData)
}

export function getmajor (query = {}) {
  return axios.get('/api/root/config/major/list', {
    params: query
  })
}

export function delmajor (id) {
  return axios.post('/api/root/config/major/del', id)
}

export function addmajor (formData) {
  return axios.post('/api/root/config/major/add', formData)
}

export function updmajor (formData) {
  return axios.post('/api/root/config/major/upd', formData)
}

export function getClassList (query = {}) {
  return axios.get('/api/root/classes/classlist', {
    params: query
  })
}

export function getMajorList (query = {}) {
  return axios.get('/api/root/config/major/allList', {
    params: query
  })
}
